Developer Documentation

QuickTime 4 API Documentation

3D Graphics Programming with QuickDraw 3D 1.5.4

Previous | QD3D Book | Overview | Chapter Contents | Next |

Managing Direct Draw Surface Draw Contexts

QuickDraw 3D provides routines that you can use to create and manipulate direct draw surface draw contexts.

Windows 32 draw contexts are always implicitly single buffered.

Q3DDSurfaceDrawContext_New

You can use the Q3DDSurfaceDrawContext_New function to create a new Direct Draw surface draw context object.

TQ3DrawContextObject Q3DDSurfaceDrawContext_New (const TQ3DDSurfaceDrawContextData
                     *drawContextData);
drawContextData
Pointer to a Direct Draw surface draw context data structure.
return value
A Direct Draw surface draw context object.

DESCRIPTION

Q3DDSurfaceDrawContext_New returns a Direct Draw surface draw context object if it is successful; otherwise it returns NULL . The application must set up the necessary data structure, as described in "Direct Draw Surface Draw Context Structure" .

Q3DDSurfaceDrawContext_GetDirectDrawSurface

You can use the Q3DDSurfaceDrawContext_GetDirectDrawSurface function to retrieve the surface descriptor associated with a Direct Draw surface draw context object.

TQ3Status Q3DDSurfaceDrawContext_GetDirectDrawSurface (
                     TQ3DrawContextObject drawContext,
                     TQ3DDSurfaceDescriptor *ddSurfaceDescriptor);
drawContext
A draw context object.
ddSurfaceDescriptor
A surface descriptor (see "Direct Draw Surface Draw Context Structure" ).

DESCRIPTION

Q3DDSurfaceDrawContext_GetDirectDrawSurface returns in ddSurfaceDescriptor the Direct Draw surface descriptor that is associated with the draw context object specified by drawContext .

Q3DDSurfaceDrawContext_SetDirectDrawSurface

You can use the Q3DDSurfaceDrawContext_SetDirectDrawSurface function to set the surface descriptor associated with a Direct Draw surface draw context object.

TQ3Status Q3DDSurfaceDrawContext_SetDirectDrawSurface (
                     TQ3DrawContextObject drawContext,
                     const TQ3DDSurfaceDescriptor *ddSurfaceDescriptor);
drawContext
A draw context object.
ddSurfaceDescriptor
A surface descriptor (see "Direct Draw Surface Draw Context Structure" ).

DESCRIPTION

Q3DDSurfaceDrawContext_SetDirectDrawSurface sets the draw context object identified by drawContext to use the surface descriptor specified by ddSurfaceDescriptor.


© 1997 Apple Computer, Inc.

Previous | QD3D Book | Overview | Chapter Contents | Next |